package com.ymh.spring.learn.mq.activitymq.consumer;

import javax.jms.JMSException;
import javax.jms.Message;
import javax.jms.MessageListener;
import javax.jms.TextMessage;
/**
 * 
 *项目名称：spring-mq
 *功能描述：
 * 
 * @author aivin
 * @version 1.0.0
 * ©版权所有 杨明华
 */
public class ConsumerMessageListener implements MessageListener {

	public void onMessage(Message arg0) {
		TextMessage textMessage = (TextMessage) arg0;
		try {
			System.out.println("接收消息" + textMessage.getText());
		} catch (JMSException e) {
			e.printStackTrace();
		}

	}

}
